<?php
include 'head.php';
include 'conn.php';
if ($_POST['submit'])
{
	$SQL = "insert into message (`id`, `user`, `title`, `content`, `lastdate`) VALUES (NULL, '$_POST[user]', '$_POST[title]', '$_POST[content]', now())";
	mysql_query($SQL);
	echo "successful insertion";
}

?>
<form method="post" action="index.php">
user name:<input type="text" name="user" /><br /><br />
title:<input type="text" name="title" /><br /><br />
content:<textarea name="content" id="textarea" cols="45" rows="5"></textarea>
<input type="submit" name="submit" value="submit"/>
</form>
